//
//  Rank3.m
//  FloatClouds
//
//  Created by 黄威 on 16/9/7.
//  Copyright © 2016年 黄威. All rights reserved.
//



#import "Rank3.h"
#import "Rank3Cigarette.h"

@implementation Rank3

-(void)setValue:(id)value forKey:(NSString *)key{
    
    [super setValue:value forKey:key];
    
    if ([key isEqualToString:@"cigarettes"]) {
        
        NSMutableArray *array = [NSMutableArray array];
        
        for (NSDictionary *dic in value) {
            
            Rank3Cigarette *cigarettes = [Rank3Cigarette modelWithDic:dic];
            
            [array addObject:cigarettes];
            
        }
        
        _cigarettes = array;
        
    }

}

@end